package com.zwy.ubts.dao;

import com.zwy.ubts.bean.Book;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * @Author Zhou Wenying
 * @Description:
 * @Date Created in 23:37 2023/3/7
 */
public interface BookDao extends BaseDao {
    int insertBook(Book book); //添加书籍
    List<Book> selectHotBook();
    List<Book> selectNewBook();
    List<Book> selectAllBook(@Param("like") String like);//模糊查询图书
    List<Book> selectBookByUserId(@Param("userId") Integer userId); //根据用户id查询图书
    List<Book> selectBookByCheck();//查询未审核的
    Integer deleteBookById(@Param("bookId") Integer bookId);//通过bookid删除书籍信息
    Book selectByBookId(@Param("bookId") Integer bookId); //通过bookid查看书籍信息
    List<Book> queryBookByClassify(@Param("bookClassify") Integer bookClassify,@Param("like") String like);//通过类别id显示书籍
    Integer updateBookById(Book book); //更新图书信息
}
